﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Windows.Controls;

namespace FinalProject.UI.Controls
{
    public class HTabItem : TabItem
    {
        public delegate void FormToEditMode(object sender, EventArgs e);
        public event FormToEditMode FormToEditModeEvent;
        protected void OnSwitchToEditMode(object sender, EventArgs e)
        {
            if (FormToEditModeEvent != null)
            {
                this.FormToEditModeEvent(sender, e);
            }
        }

        private bool _editMode;
        public bool InEditMode
        {
            get
            {
                return this._editMode;
            }
            set
            {
                this._editMode = value;
                OnSwitchToEditMode(this, EventArgs.Empty);
            }
        }

        public HTabItem()
            : base()
        {
        }
    }
}

